package cc.chengheng.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;

@Controller
public class CsrfController {

    @GetMapping("/to-update")
    public String test(Model model) {
        return "csrf/csrf-test";
    }

    @PostMapping("/update-token")
    public String getToken(Model model) {
        return "csrf/csrf-token";
    }
}
